$(function(){
	//页面加上查询条件
	showCondition(true);
	paramTabPage[tabId]= $("#tabContent > .tab-pane.active").data();
	var totalQuota = [{
				code : 'drg',
				name : 'DRG指标',
				data : [{
							name : "产能指标",
							data : [{
										"quotaCode" : "TotalCaseCnt",
										"quotaName" : "出院人数"
									},{ 
									     "quotaCode":"TotalFee",
									     "quotaName":"总费用(万元)"											     
									  }]
						}, {
							name : "效率指标",
							data : [{
										"quotaCode" : "AvgDays",
										"quotaName" : "平均住院日"
									}, {
										"quotaCode" : "AvgFee",
										"quotaName" : "次均费用"
									}]
						}, {
							name : "安全指标",
							data : [{
										"quotaCode" : "DeadRatio",
										"quotaName" : "死亡率(%)",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "InfRatio",
										"quotaName" : "药院内感染率(%)",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "DeadCaseCnt",
										"quotaName" : "死亡人数"
									}, {
										"quotaCode" : "DrugRatio",
										"quotaName" : "药占比(%)",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "AntiRatio",
										"quotaName" : "抗生素使用率(%)",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "Oper2Ratio",
										"quotaName" : "二次手术比率(%)",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "DrugFee",
										"quotaName" : "药品费用(万元)"
									}, {
										"quotaCode" : "MaterialFee",
										"quotaName" : "材料费用(万元)"
									}, {
										"quotaCode" : "MaterialRatio",
										"quotaName" : "材料费用占比(%)",
										"quotaType":"ratio"
									}]
						}]
			}];
	var defenQuota = [{
						code : 'depGroup',
						name : 'DRG指标',
						data : [{
								name : "科室DRG评价",
								data : [{
											"quotaCode" : "TotalScore",
											"quotaName" : "综合得分"
										},{ 
										     "quotaCode":"CapacityScore",
										     "quotaName":"产能得分"											     
										  },{ 
										     "quotaCode":"EfficiencyScore",
										     "quotaName":"效率得分"											     
										  },{ 
										     "quotaCode":"QualityScore",
										     "quotaName":"安全得分"											     
										  }]
								}]
					}];
	var drgsQuota = [{
				code : 'drgs',
				name : 'DRG指标',
				data : [{
							name : "产能指标",
							data : [ {
								     "quotaCode":"CMI", 
							         "quotaName":"CMI值"
							        },{
					                	"quotaCode":"DRGCount",
					                	"quotaName":"DRGs组数"
					                },{
					                	"quotaCode":"TotalWeight", 
					                	"quotaName":"总权重"
					                },{
					                	"quotaCode":"InCaseCnt", 
					                	"quotaName":"入组病例"
					                }]
						}, {
							name : "效率指标",
							data : [{
										"quotaCode" : "TimeEff",
										"quotaName" : "时间消耗指数"
									}, {
										"quotaCode" : "FeeEff",
										"quotaName" : "费用消耗指数"
									}, {
										"quotaCode" : "WeightPerDoctor",
										"quotaName" : "每医师权重"
									}, {
										"quotaCode" : "WeightPerBedDays",
										"quotaName" : "每床日权重"
									}]
						}, {
							name : "安全指标",
							data : [{
										"quotaCode" : "Risk1Ratio",
										"quotaName" : "低风险死亡率",
										"quotaType":"ratio"
									}, {
										"quotaCode" : "Risk2Ratio",
										"quotaName" : "中低风险死亡率",
										"quotaType":"ratio"
									}]
						}]
			}];				
	//加载开始界面正在加载数据样式
	
	//全院指标 (1.Hosp 2.All)
//	loadyzhangAllQuota("depGroup","All",drgsQuota,"yzhangAllDepQuotasId","yzhangAllDep-ul");
	loadHospQuota("depGroup", drgsQuota, "yzhangAllDepQuotasId");
    //**************加载科室组drgs评价部分**********************
	//加载科室组drgs评价div页面布局
	loadDepGroupDrgsQuota(defenQuota,"科室","yzhangdepgroupdrgsdepQuotasId","yzhangdepgroupdrgsdep-ul");
	//为下半部分加载数据 
	loadDepGroupQuotaData(defenQuota,"dep","","");	
	//**************加载drgs指标详情部分**********************
	//加载科室组drgs指标详情
	loadDepGroupDrgsQuota(drgsQuota,"科室","yzhangDrgsDepQuotasIda","yzhangdrgsdep-ul");
    //为下半部分加载数据 
	loadDepGroupQuotaData(drgsQuota,"dep","","loadDepToMdc");	
    //移除正在加载数据部分
   $(document).ajaxStop(function(){
		
	  });	
});

function loadDepToMdc(code,desc){
	var param = jQuery.extend(true,{},paramTabPage[tabId]);
	 param.depCode = code;

	openTab('/pages/yzHome/yzhangHomeMdc.jsp',desc+'|MDC','deptomdc'+code,'deptomdc'+code,param);

}




